﻿namespace Entity
{
    /// <summary>
    /// 拼团奖品领取表
    /// </summary>
    public class TeamBuyPrize : BaseEntity
    {
        /// <summary>
        /// 所属拼团
        /// </summary>
        public int TeambuyId { get; set; }

        /// <summary>
        /// 所属用户
        /// </summary>
        public int UserId { get; set; }

        /// <summary>
        /// 所属商品
        /// </summary>
        public int ProductId { get; set; }

        /// <summary>
        /// 所属商户
        /// </summary>
        public int StoreId { get; set; }

        /// <summary>
        /// 是否领奖
        /// </summary>
        public bool IsResolve { get; set; }

        /// <summary>
        /// 快递单
        /// </summary>
        public int ExpressId { get; set; }


        /// <summary>
        /// 用户信息
        /// </summary>
        [Navigate(NavigateType.OneToOne, nameof(UserId))]
        public Entity.Client? User { get; set; }

        /// <summary>
        /// 产品信息
        /// </summary>
        [Navigate(NavigateType.OneToOne, nameof(ProductId))]
        public Entity.TeamBuyProduct? Product { get; set; }

        /// <summary>
        /// 快递信息
        /// </summary>
        [Navigate(NavigateType.OneToOne, nameof(ExpressId))]
        public Entity.Express? ExpressInfo { get; set; }

        /// <summary>
        /// 商户信息
        /// </summary>
        [Navigate(NavigateType.OneToOne, nameof(StoreId))]
        public Entity.Store? Store { get; set; }
    }


}
